//
//  EditDPDetailViewController.h
//  TimeManager
//
//  Created by 刘凯敏 on 04/12/2016.
//  Copyright © 2016 刘凯敏. All rights reserved.
//

#import <UIKit/UIKit.h>

@class EditDPDetailViewController,DPDetailModel;

//定义一个协议
@protocol EditDPDetailControllerDelegate <NSObject>
@optional
- (void) editContact:(EditDPDetailViewController *)editVc didSaveContact:(DPDetailModel *)contact;
@end

@interface EditDPDetailViewController : UIViewController
@property (strong, nonatomic) IBOutlet UITextField *nameField;
@property (strong, nonatomic) IBOutlet UITextField *placeField;
- (IBAction)editEnd:(id)sender;
@property (strong, nonatomic) IBOutlet UIButton *saveBtn;
- (IBAction)saveAction:(id)sender;
@property (strong, nonatomic) IBOutlet UIBarButtonItem *edit;
- (IBAction)editAction:(UIBarButtonItem *)sender;
- (IBAction)backTap:(id)sender;

@property (nonatomic, strong) DPDetailModel *contactModel;
//声明代理属性
@property (nonatomic, weak) id<EditDPDetailControllerDelegate> delegate;
@end
